package com.sunshine.springboot.dto.properties;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * Demo class
 *
 * @author WeiHong
 * @date 2018/8/14
 */
@Component
@PropertySource("classpath:my2.properties")
@ConfigurationProperties(prefix = "my2")
@Getter
@Setter
@ToString
public class My2Properties {
    private int age;
    private String name;
    private String email;
}
